1. Field of the Invention
The present invention relates to an image processing apparatus and method for encoding image data, and a recordng medium storing a computer program for this method.
2. Description of the Related Art
In accordance with recent remarkable improvement in the performance of PCs (personal computers), image data is widely used in the PCs. Usually, image data is represented in the form of a digital signal string in the PC. Since each pixel corresponds to one piece of data, there is a very large amount of image data. Particularly when image data is dealt with in a computer or on a network where computers are interconnected, the amount of data causes, in some cases, problems.
In the above-described situations, when storing and transmitting image data, compression encoding of the image data is widely performed. So-called JPEG (Joint Photographic Experts Group), serving as a standard method for compressing a multivalue still image according to ITU-T (International Telecommunication Union-Telecommunication Standardization Sector) recommendation T.81, is known as such an image compression technique. The JPEG is particularly suitable for compressing a natural image. In the JPEG, an image to be encoded is divided into blocks, each having a size of 8xc3x978 pixels, and discrete cosine transformation is performed for each of the blocks. Obtained transformation coefficients are quantized and are subjected to entropy encoding.
As the instances of dealing with image data in a PC increase as a result of the diffusion of computers, digital cameras and the like, there is an increasing necessity for processing/editing the image data. In such uses, image data is desirably configured in units of a certain object constituting each image.
For example, when it is intended to perform color balance adjustment only for a person in an image where the person is present in front of a background, it is easy to process only the person if the background and the person are included in the image data as data of different units.
For example, when executing JPEG compression encoding, an image to be encoded is divided into blocks in encoding processing. Basically, the entire image is subjected to encoding. Hence, when performing processing, such as color balance adjustment or the like, for an image subjected to JPEG compression encoding, it is necessary to process an object after extracting it from a decoded image.
On the other hand, techniques for performing compression encoding for each object are being studied as methods for encoding a moving image.
However, an efficient method for performing compression encoding of each object within a still image has not yet been established.
It is an object of the present invention to solve the above-described problems.
It is another object of the present invention to provide an encoding method for efficiently encoding information relating to a multivalue image having an arbitrary shape, i.e., a rectangular or non-rectangular shape.
According to one aspect, the present invention which achieves the above-described object relates to an image processing apparatus including input means for inputting a multivalue image, first transformation means for transforming the multivalue image input by the input means with a first transformation method and for generating first transformation coefficients, second transformation means for transforming shape information indicating a shape of the multivalue image transformed by the first transformation means with a second transformation method different from the first transformation method and for generating second transformation coefficients, and encoding means for encoding each of blocks configured by the first transformation coefficients and blocks configured by the second transformation coefficients using a common encoding method.
According to another aspect, the present invention relates to an image processing method including an input step of inputting a multivalue image, a first transformation step of transforming the multivalue image input in the input step with a first transformation method and generating first transformation coefficients, a second transformation step of transforming shape information indicating a shape of the multivalue image transformed in the first transformation step with a second transformation method different from the first transformation method and generating second transformation coefficients, and an encoding step of encoding each of blocks configured by the first transformation coefficients and blocks configured by the second transformation coefficients using a common encoding method.
According to still another aspect, the present invention relates to a storage medium storing an image processing program so as to be readable from a computer. The image processing program includes an input step of inputting a multivalue image, a first transformation step of transforming the multivalue image input in the input step with a first transformation method and generating first transformation coefficients, a second transformation step of transforming shape information indicating a shape of the multivalue image transformed in the first transformation step with a second transformation method different from the first transformation method and generating second transformation coefficients, and an encoding step of encoding each of blocks configured by the first transformation coefficients and blocks configured by the second transformation coefficients using a common encoding method.
It is still another object of the present invention to efficiently encode information relating to a multivalue image having an arbitrary shape by providing a new encoding method as a part of the above-described encoding method.
According to yet another aspect, the present invention which achieves the above-described object relates to the image processing apparatus wherein the encoding means generates encoded data including information indicating positions of efficient transformation coefficients by repeating division processing for each of the blocks configured by the first transformation coefficients and the blocks configured by the second transformation coefficients, and outputs the encoded data.
It is yet another object of the present invention to provide an encoding method capable of efficiently encoding a plurality of types of image data obtained from the same multivalue image.
According to yet a further aspect, the present invention which achieves the above-described object relates to an image processing apparatus including input means for inputting a multivalue image, first transformation means for transforming the multivalue image input by the input means with a first transformation method and for generating first transformation coefficients, second transformation means for transforming another image obtained from the multivalue image transformed by the first transformation means with a second transformation method different from the first transformation method and for generating second transformation coefficients, and encoding means for encoding each of blocks configured by the first transformation coefficients and blocks configured by the second transformation coefficients using a common encoding method.
It is yet a further object of the present invention to efficiently encode the plurality of kinds of image data by providing a new encoding method as a part of the above-described encoding method.
According to still another aspect, the present invention which achieves the above-described object relates to the image processing apparatus wherein the encoding means generates encoded data including information indicating positions of efficient transformation coefficients by repeating division processing for each of the blocks configured by the first transformation coefficients and the blocks configured by the second transformation coefficients, and outputs the encoded data.
According to still another aspect, the present invention relates to an image processing method including an input step of inputting a multivalue image, a first transformation step of transforming the multivalue image input in the input step with a first transformation method and for generating first transformation coefficients, a second transformation step of transforming another image obtained from the multivalue image transformed in the first transformation step with a second transformation method different from the first transformation method and generating second transformation coefficients, and an encoding step of encoding each of blocks configured by the first transformation coefficients and blocks configured by the second transformation coefficients using a common encoding method.
According to still another aspect, the present invention relates to a storage medium storing an image processing program so as to be readable from a computer. The image processing program includes an input step of inputting a multivalue image, a first transformation step of transforming the multivalue image input in the input step with a first transformation method and generating first transformation coefficients, a second transformation step of transforming another image obtained from the multivalue image transformed in the first transformation step with a second transformation method different from the first transformation method and generating second transformation coefficients, and an encoding step of encoding each of blocks configured by the first transformation coefficients and blocks configured by the second transformation coefficients using a common encoding method.
The foregoing and other objects, advantages and features of the present invention will become more apparent from the following detailed description of the preferred embodiments taken in conjunction with the accompanying drawings.